Skip to content

feat(evmrpc): align transaction errors with geth - #4102

Draft
alexander-sei wants to merge 1 commit into
mainfrom
rfc-009-geth-error-parity
Draft

feat(evmrpc): align transaction errors with geth#4102
alexander-sei wants to merge 1 commit into
mainfrom
rfc-009-geth-error-parity

Conversation

@alexander-sei

Copy link
Copy Markdown
Contributor

Describe your changes and provide context

Implements RFC 009 for eth_sendRawTransaction.

  • adds a single RPC-boundary translation package for CheckTx, mempool, proxy, and timeout errors
  • preserves native geth decode errors and already-typed remote JSON-RPC errors
  • adds CheckTx-only diagnostic details and EIP-7623 floor-data-gas rejection without changing DeliverTx or historical trace behavior
  • redacts proxy panic stacks and internal transport details from client responses
  • maps EIP-7702 empty authorization lists and malformed signatures to geth-compatible errors
  • adds structured IOX error assertions, signed rejection fixtures, differential checks, and a depguard ratchet
  • documents intentional Sei/geth admission differences

Unknown internal submission failures now return -32603 internal error; known geth-compatible submission failures retain -32000, and request timeouts use -32002.

Testing performed to validate your change

  • scripts/ramtest.sh ./evmrpc/... ./app/ante -run ... -count=1
  • go test ./sei-tendermint/internal/proxy -run TestCheckTxSafe -count=1
  • go test ./integration_test/evm_module/rpc_io_test -run TestParseIOFile_TestdataDir -count=1
  • npx tsc --noEmit in integration_test/rpc_tests
  • node --check contracts/test/lib.js
  • node --check contracts/test/EVMCompatabilityTest.js
  • make fmtcheck
  • scoped golangci-lint over the changed Go packages
  • git diff --check

The live Docker RPC integration suite was not run locally; keeping this PR in draft until that environment-backed gate runs.

Co-authored-by: Cursor <cursoragent@cursor.com>
@github-actions

github-actions Bot commented Sep 7, 2026

Copy link
Copy Markdown

The latest Buf updates on your PR. Results from workflow Buf / buf (pull_request).

BuildFormatLintBreakingUpdated (UTC)
✅ passed✅ passed✅ passed✅ passedSep 7, 2026, 10:44 AM

@codecov

codecov Bot commented Sep 7, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 78.40909% with 38 lines in your changes missing coverage. Please review.
✅ Project coverage is 60.28%. Comparing base (abdcc45) to head (02e7602).

Files with missing lines Patch % Lines
app/ante/evm_checktx.go 51.72% 11 Missing and 3 partials ⚠️
integration_test/evm_module/rpc_io_test/io.go 48.14% 7 Missing and 7 partials ⚠️
evmrpc/send.go 76.92% 4 Missing and 2 partials ⚠️
evmrpc/ethrpcerrors/errors.go 95.60% 2 Missing and 2 partials ⚠️
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #4102      +/-   ##
==========================================
- Coverage   61.21%   60.28%   -0.94%     
==========================================
  Files        2196     2088     -108     
  Lines      193395   180580   -12815     
==========================================
- Hits       118386   108854    -9532     
+ Misses      63793    61584    -2209     
+ Partials    11216    10142    -1074     
Flag Coverage Δ
sei-chain-pr 70.96% <78.40%> (?)
sei-db 69.80% <ø> (ø)
sei-db-state-db ?

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
sei-tendermint/internal/proxy/proxy.go 89.39% <100.00%> (+0.33%) ⬆️
evmrpc/ethrpcerrors/errors.go 95.60% <95.60%> (ø)
evmrpc/send.go 62.41% <76.92%> (+9.21%) ⬆️
app/ante/evm_checktx.go 44.73% <51.72%> (+1.17%) ⬆️
integration_test/evm_module/rpc_io_test/io.go 72.45% <48.14%> (-2.19%) ⬇️

... and 112 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant